import Vue from 'vue'
import Router from 'vue-router'
//import Index from '@/views/Index'
const Index = () =>import('../views/Index')
//import Projects from '@/components/Projects'
const Projects =() =>import('@/components/Projects')
// import AllProjects from '@/components/AllProjects'
const AllProjects =()=>import('@/components/AllProjects')
// import ProjectApply from '@/components/ProjectApply'
const ProjectApply =()=> import('@/components/ProjectApply')
// import MoneyApply from '@/components/MoneyApply'
const MoneyApply =()=>import('@/components/MoneyApply')
// import GoodPeople from '@/components/GoodPeople'
const GoodPeople =()=> import('@/components/GoodPeople')
// import AddGoodPeople from '@/components/AddGoodPeople'
const AddGoodPeople =()=>import('@/components/AddGoodPeople')
// import Upload from "../components/Upload";
const Upload =() =>import("../components/Upload")
// import Project from "../components/Project";
const Project =()=>import("../components/Project")
// import ShenpiIncome from "../components/ShenpiIncome";
const ShenpiIncome =()=> import("../components/ShenpiIncome")
// import AddGoodMoney from '@/components/AddGoodMoney'
const AddGoodMoney =() => import('@/components/AddGoodMoney')
// import Login from '../components/Login'
const Login =() =>  import('../components/Login')
// import ShenpiExpense from "../components/ShenpiExpense";
const ShenpiExpense =()=> import("../components/ShenpiExpense")
// import ChangeGoodPeople from "../components/ChangeGoodPeople";
const ChangeGoodPeople =()=> import("../components/ChangeGoodPeople")
// import CloseProject from "../components/CloseProject";
const CloseProject =() =>  import("../components/CloseProject")
Vue.use(Router)

export default new Router({
  mode:'history',
  routes: [
    {
      path: '/view',
      name: 'Index',
      component:Index,
      children:[
        {
          path: '/projects',
          name: 'Projects',
          component: Projects
        },{
          path: '/project',
          name: 'Project',
          component: Project
        },
        {
          path: '/allProjects',
          name: 'AllProjects',
          component: AllProjects
        },
        {
          path: '/projectApply',
          name: 'ProjectApply',
          component: ProjectApply
        },
        {
          path: '/moneyApply',
          name: 'MoneyApply',
          component: MoneyApply
        },
        {
          path: '/upload',
          name: 'Upload',
          component: Upload
        },
        {
          path: '/projectinfo',
          name: 'project',
          component: Project
        },
        {
          path: '/goodPeople',
          name: 'GoodPeople',
          component: GoodPeople
        },
        {
          path: '/addGoodPeople',
          name: 'AddGoodPeople',
          component: AddGoodPeople
        },
        {
          path: '/shenpiExpense',
          name: 'shenpiExpense',
          component: ShenpiExpense
        },
        {
          path: '/shenpiIncome',
          name: 'ShenpiIncome',
          component: ShenpiIncome
        },
        {
          path: '/addGoodMoney',
          name: 'AddGoodMoney',
          component: AddGoodMoney
        },
        {
          path: '/changeGoodPeople',
          name: 'ChangeGoodPeople',
          component: ChangeGoodPeople
        },
        {
          path: '/closeProject',
          name: 'CloseProject',
          component: CloseProject
        },
      ],
    },
    {
      path: '/',
      name: 'Login',
      component:Login
    }
  ]
})
